<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html class=" -webkit-">
	<head>	
		<meta charset="utf-8">
		<title>${adminname}</title>
		<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
		<meta content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport">
		<meta content="application/xhtml+xml;charset=UTF-8" http-equiv="Content-Type">
		<meta content="no-cache,must-revalidate" http-equiv="Cache-Control">
		<meta content="no-cache" http-equiv="pragma">
		<meta content="0" http-equiv="expires">
		<meta content="telephone=no, address=no" name="format-detection">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
		<link rel="stylesheet" type="text/css" href="${ctxStatic}/jiu/css/mobile_module.css?v=1492648593" media="all">
	    <link rel="stylesheet" href="${ctxStatic}/jiu/css/font-awesome.min.css" />
		<script type="text/javascript">
			//静态变量
			 var WX_APPID = "wxdd0a52b5ade820ba";
			var WXJS_TIMESTAMP = '1492648593';
			var NONCESTR = 'wb03tri4jVWJDK6S';
			var SIGNATURE = '1d9c103ed1aa1597e5be8e1056a9f1764f42df75';
		</script>
		<script type="text/javascript" src="${ctxStatic}/jiu/js/jquery-2.0.3.min.js"></script>
		<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
		<script type="text/javascript" src="${ctxStatic}/jiu/js/prefixfree.min.js?v=1492648593"></script>
		<script type="text/javascript" src="${ctxStatic}/jiu/js/dialog.js?v=1492648593"></script>
		<script type="text/javascript" src="${ctxStatic}/jiu/js/flipsnap.min.js?v=1492648593"></script>
		<script type="text/javascript" src="${ctxStatic}/jiu/js/mobile_module.js?v=1492648593"></script>
		<link href="${ctxStatic}/jiu/css/common.css?v=1492648593" rel="stylesheet" type="text/css">
		<link href="${ctxStatic}/jiu/css/shop.css?v=1492648593" rel="stylesheet" type="text/css">
		<script type="text/javascript" src="http://www.zhangxinxu.com/study/js/mini/jquery.scrollLoading-min.js"></script>		
	</head>
	<body class="withFoot">
		<style>
			.shoplog {
				position: absolute;
				top: -15px;
				z-index: 100;
				width: 60px;
				height: 60px;
				border: 2px solid #888;
				border-radius: 36px;
				padding: 1px;
				background-color: #FFFFFF;
			}
			.actGotop {
			    position: fixed;
			    bottom: 70px;
			    right: 10px;
			    display: none;
			    z-index: 22222;
			}
			.actGotop img{
			    width: 40px;
			}
			.xinyu {
				display: -webkit-flex;
				/* Safari */
				display: flex;
				flex-direction: row;
				-webkit-align-items:flex-start;
				align-items:flex-start;
				-webkit-justify-content: space-around;
				justify-content: space-around;
				-webkit-flex-direction: row;
			
			}	
			.product_list li a {
	background: #fff;
	display: block;
}

.product_list li  .tou {
	width: 90%;
	padding-left: 5%;
	padding-top: 5%;
	height: 140px;
}

.product_list li  .desc {
	padding-bottom: 5%;
	/*border-top: 1px solid #ddd;*/
	padding-left: 5%;
}

.product_list li  .name {
	margin-top: 5px;
	line-height: 18px;
	
	font-size: 16px;
	height: 18px;
	color: #666;
	overflow: hidden;
	width: 90%;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.product_list li  .price {
	color: #f44805;
	font-size: 15px;
}
.shop_fenlie table {
	width: 100%;
	text-align: center;
	padding: 15px 0px;
	border-collapse: collapse;
	border-spacing: 0;
	border: 1px solid #eee;
}
.shop_fenlie table tr td{
	padding: 10px 0px;
}
			
			
		</style>
		<div class="container">
			<div class="search_form">
				<a href="javascript:void(0);" class="cate_icon"> </a>
				<input type="text" placeholder="请输入厂家名称" value="" name="search_key" id="search_key">

				<button type="button" id="search" url="" onclick="searchFactor()">搜索</button>
			</div>
			<!-- banner -->
			<div class="banner" style="height: 187.5px;">
				<ul style="width: 1125px; height: 187.5px; transition-property: transform; transition-timing-function: cubic-bezier(0, 0, 0.25, 1); transition-duration: 350ms; transform: translate3d(-750px, 0px, 0px);">
					 <c:forEach items="${jiuCarouselList}" var="jiuCarousel">
						<li style="width: 375px; height: 187.5px;">
							<a href="${jiuCarousel.url}"><img src="${ctxUser }/jiu/${jiuCarousel.ico}" style="width: 375px; height: 187.5px;"></a>
						</li>
					</c:forEach>
				</ul>
				<span class="identify">            	
	           	     <c:forEach items="${jiuCarouselList}" var="jiuCarousel"   varStatus="vstatus">
				            <em class="${vstatus.index eq 0?'cur':''}"></em>
					 </c:forEach> 
            	</span>
			</div>
			<!-- 店标和名称 -->
			<div class="shop_row">
				<div class="shoplog">
					<c:choose>
					    <c:when test="${empty jiuStore.logo}">
					     <img src="${jiuStore.headimgurl}">
					    </c:when>
					    <c:otherwise>
					      <img src="${ctxUser }/jiu/${jiuStore.logo}">
					    </c:otherwise>
					</c:choose>
					
				</div>
				<span>
				${jiuStore.name}<br>
				<i>积分:${jiuStore.point}<img src="${ctxStatic}/jiu/img/jifen.png" width="10px" height="10px"></i>          
			  </span>
				
				<c:if test="${jiuStore.identity eq 1}">
					<a href="javascript:register()">
						<img src="${ctxStatic}/jiu/img/wanshan.png" style="position: absolute; border-radius: 0; right: 10px; top: 5px; width: 60px; height: 60px;">
					</a>
                </c:if>
			</div>
			<div class="shop_fenlie">
				<a href="javascript:rechargeMenu()"><img src="${ctxStatic}/jiu/img/chzh.jpg"></a>
			</div>
			
			<h6 class="cate_title" alt="12">厂家分类</h6>
			
			<div class="shop_fenlie" style="margin-top: 10px;">
				
				<table border="1">
				<tbody>
				<tr>
					<c:forEach items="${jiuManufactorClassList}" var="jiuManufactorClass" varStatus="status">
							<td >
								<a href="javascript:factorClassList(${jiuManufactorClass.id})">
									<img class="scrollLoading" data-url="${ctxUser }/jiu/${jiuManufactorClass.ico}" src="${ctxUser }/jiu/${jiuManufactorClass.ico}" style="vertical-align: top;" width="40px"><br>${jiuManufactorClass.name}
								</a>
							</td>
							
							<c:if test="${status.count % 3 == 0}">
							</tr>
							<tr>
							</c:if>
					</c:forEach>
					
				</tr>
				</tbody>
				</table>
			</div>
			
			<c:if test="${not empty jiuManufactorList}">
				<div class="">
					<h6 class="cate_title" alt="12">推荐厂家</h6>
				</div>
				<div class="product_list">
		            <ul id="productContainer">
		            	<c:forEach items="${jiuManufactorList}" var="jiuManufactor">
		            	 <a href="javascript:factorDetails(${jiuManufactor.id})">
							<li class="contentItem " >
		                       
		                           
<%-- 		                            <img class="scrollLoading" src="${ctxUser }/jiu/${jiuManufactor.logo}">
 --%>			                   	<img class="scrollLoading tou" src="${ctxUser }/jiu/${jiuManufactor.logo}">
			                   
			                   
			                   
		                            <div class="desc" style="width:50%;">
		                            	<p class="name" >${jiuManufactor.name}</p>
		                            </div>
		                           <div style="margin-top: 5px;margin-left: 10px;">
				                        <span style="font-size: 14px;">等级:</span>
				                       <img src="${ctxStatic }/jiu/ratingimg/${jiuManufactor.creditRating.ratingpic}" style="height: 15px;"/>				
				                    </div>
		                        
			                      
			                        	<div style="margin-left: 10px;font-size: 14px;">
			                        		<p >销量:&nbsp;${jiuManufactor.salesnum}</p>
			                        	</div>
			                        	<div style="margin-left: 10px;font-size: 14px;padding-bottom: 5px;">
			                        		<span >综合评价: </span>&nbsp;<span class="orange">${jiuManufactor.allscore}分</span>
			                        	</div>
		                    
		                      
	                		</li>
	                		   </a>
						</c:forEach>
		            </ul>
	        	</div>
            </c:if>
			
			
			<c:if test="${not empty jiuManufactorAllList}">
				<div class="">
				<h6 class="cate_title" alt="12">厂家列表</h6>
				
			</div>
			
			 <div class="product_list">
	            <ul id="productContainer">
	            	<c:forEach items="${jiuManufactorAllList}" var="jiuManufactor">
						<%-- <li class="contentItem" >
	                    
	                        <a href="javascript:factorDetails(${jiuManufactor.id})">
	                            <img class="scrollLoading" src="${ctxUser }/jiu/${jiuManufactor.logo}">
	                            <div class="desc">
	                            	<p class="name">${jiuManufactor.name}</p>
                            	<p class="price">${jiuManufactor.price}积分</p>
	                            </div>
	                        </a>
	                        
	                       
	                     
                		</li>
                		
                		 --%>
                		 
                		  <a href="javascript:factorDetails(${jiuManufactor.id})">
							<li class="contentItem " >
		                       
		                           
			                   	<img class="scrollLoading tou" src="${ctxUser }/jiu/${jiuManufactor.logo}">
			                   
			                   
			                    <%-- 
		                            <div class="desc" style="width:50%;">
		                            	<p class="name" >${jiuManufactor.name}</p>
		                            </div>
		                            <div style="margin-top: 5px;margin-right: 5px;width: 50%;text-align: right;">
		                            	<!-- <img src="images/huan.png" style="height: 15px;"/> -->
		                            
										<img src="${ctxStatic }/jiu/ratingimg/${jiuManufactor.creditRating.ratingpic}" style="height: 15px;"/>
				
		                            </div>
		                        
			                        <div class="xinyu" style="width: 100%;">
			                        	<div style="width:40%;margin-left: 10px;">
			                        		<p >销量${jiuManufactor.salesnum}</p>
			                        	</div>
			                        	<div style="width:60%;text-align: right;margin-right: 10px;">
			                        		<span >综合评价 </span><span class="orange">${jiuManufactor.allscore}分</span>
			                        	</div>
		                       		 </div> --%>
		                      
		                      
		                       <div class="desc" style="width:50%;">
		                            	<p class="name" >${jiuManufactor.name}</p>
		                            </div>
		                           <div style="margin-top: 5px;margin-left: 10px;">
				                        <span style="font-size: 14px;">等级:</span>
				                       <img src="${ctxStatic }/jiu/ratingimg/${jiuManufactor.creditRating.ratingpic}" style="height: 15px;"/>				
				                    </div>
		                        
			                      
			                        	<div style="margin-left: 10px;font-size: 14px;">
			                        		<p >销量:&nbsp;${jiuManufactor.salesnum}</p>
			                        	</div>
			                        	<div style="margin-left: 10px;font-size: 14px;padding-bottom: 5px;">
			                        		<span >综合评价: </span>&nbsp;<span class="orange">${jiuManufactor.allscore}分</span>
			                        	</div>
	                		</li>
	                		   </a>
					</c:forEach>
	            </ul>
        	</div>
            </c:if>
			
		</div>
		
	 	<!-- 底部导航 -->
		<%@ include file="/WEB-INF/views/modules/jiuFront/footer.jsp"%>

		<script type="text/javascript">
			$(function() {
				$(".scrollLoading").scrollLoading();
				//通用banner 滑动
				$.WeiPHP.initBanner(true, 5000);

				$("#search_key").bind('keyup',function(event){
				    event=document.all?window.event:event;
				    if((event.keyCode || event.which)==13){
				    	searchFactor();
				    }
				   });
			})
		</script>
		
		<script>
			function searchFactor(){
				var name=$('#search_key').val();
				window.location.href="${ctxFront }/jiu/searchFactor?uid=${uid}&name="+name;
			}
		
			//充值菜单
			function rechargeMenu(){
				window.location.href="${ctxFront }/jiu/rechargeMenu?uid=${uid}&v="+Math.random();
			}
			
			//注册
			function register(){
				window.location.href="${ctxFront }/jiu/register?uid=${uid}&v="+Math.random();
			}
			
			
			//厂家列表
			function factorClassList(classId){
				window.location.href="${ctxFront }/jiu/factorClassList?uid=${uid}&classId="+classId;
			}
			
			//厂家详情
			function factorDetails(id){
				window.location.href="${ctxFront }/jiu/factorDetails?uid=${uid}&factorId="+id+"&v="+Math.random();
			}
		</script>		
	</body>
</html>